const { defineConfig } = require('@vue/cli-service')
module.exports = defineConfig({
  transpileDependencies: true,
  devServer: {
    port: 8085,   //服务端口
    client: {  // 解决页面弹出红色报错遮罩层
      overlay: false,//将overlay设置为false即可
    },
    proxy: {         //代理请求
      "/api": {
        target: "http://127.0.0.1:8087",   //将以/api开头的请求都转发到该地址
        changeOrigin: true,   //允许跨域
        pathRewrite: {
          '^/api': ''
        }
      }
    },
  }
})